/**
 * Package Name:cn.com.guodiantong.module.user
 * Date:2017年8月16日 下午4:24:49
 * Copyright (c) 2017 mr.luoxing@gmail.com Rights Reserved.
 *
 */

package cn.com.guodiantong.module.user;

import java.util.UUID;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import com.alibaba.dubbo.config.annotation.Reference;
import com.gdtnx.dubbo.system.api.user.domain.User;
import com.gdtnx.dubbo.system.api.user.service.IUserService;

import cn.com.guodiantong.common.api.annotation.Logger;
import cn.com.guodiantong.common.api.enums.LoggerEnum;
import cn.com.guodiantong.common.api.service.ILoggerService;

/**
 * @ClassName: UserController.<br/>
 * @Description: TODO(...).<br/>
 *
 * @author Mr.Luoxing
 * @version 1.0.0
 */
@RestController
@RequestMapping("user")
public class UserController {
	
	@Reference(version = "1.0.0")
	IUserService uservice;
	
	
	@GetMapping("demo")
	@Logger(module="主项目",note="心中测试用户",type=LoggerEnum.INSERT)
	public String demo(){
		uservice.save(new User(UUID.randomUUID().toString().toUpperCase(),"张三",18,"北京市丰台区航丰路1号时代财富天地"));
		return "success";
	}
}

